import entity.Pet;
import factory.PetDaoFactory;
import service.PetService;
import service.PetServiceImpl;

public class Main {
    public static void main(String[] args) {
        //领域要修改成oracle实现，只需修改一个变量即可切换
        PetDaoFactory.defaultBeanName = "petDaoOracleImpl";
        //创建PetService
        PetService petService = new PetServiceImpl();
        Pet pet = new Pet();
        pet.setName("小马喽");
        petService.save(pet);
    }
}
